From: Sebastian Keller Date: Fri, 23 Apr 2021 14:10:52 +0000 (+0200) Subject: altTab: Avoid setting GObject property to undefined instead of null X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~616^2^2~52 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=b93bf2bd69a297e89f429fd8a71423105d43b7e9;p=gnome-shell.git altTab: Avoid setting GObject property to undefined instead of null The windowActor in the CyclerHighlight was set to undefined if this._window was null. This was causing an error when trying to set it as a property. Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4167 Part-of: --- diff --git a/js/ui/altTab.js b/js/ui/altTab.js index 3ecadad86..2ae7b6b23 100644 --- a/js/ui/altTab.js +++ b/js/ui/altTab.js @@ -427,7 +427,7 @@ class CyclerHighlight extends St.Widget { if (this._clone.source) this._clone.source.sync_visibility(); - const windowActor = this._window?.get_compositor_private(); + const windowActor = this._window?.get_compositor_private() ?? null; if (windowActor) windowActor.hide();